package my.mall.front.api.config

import org.springframework.beans.factory.annotation.Autowired
import org.springframework.context.annotation.Configuration
import org.springframework.web.method.support.HandlerMethodArgumentResolver
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer

/**
 * @author fengbo
 * @version 1.0.0
 * @date 2018/11/22 16:26
 * @since JDK 1.8
 */
@Configuration
open class WebConfig(
    private val loginResolver: LoginResolver
) : WebMvcConfigurer {

    override fun addArgumentResolvers(argumentResolvers: MutableList<HandlerMethodArgumentResolver>) {
        argumentResolvers.add(loginResolver)
    }
}
